<template>
  <div class="note">
    <div class="note-bg"></div>
    <div class="note-container">
      <div class="heed" v-if="type">注意：</div>
      <slot></slot>
    </div>
  </div>
</template>

<script>
export default {
  name: "note",
  components: {},
  props:{
    // 是否显示注意
    type:{
      type:String,
      default:''
    }
  },
  methods: {},
};
</script>

<style scoped lang="less">
.note {
  margin: 1rem 0;
  position: relative;
  .note-container {
    border-left: 0.3rem solid var(--theme-color);
    border-radius: 0.8rem;
    padding: 0.25rem 1rem;
    position: relative;
    z-index: 2;
    .heed{
      margin-bottom: 5px;
      color: var(--theme-color);
    }
  }
  .note-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    background-color: var(--theme-color);
    opacity: 0.2;
    border-radius: 0.8rem;
    // border-top-left-radius: 0.8rem;
  }
}
</style>